﻿using System.Windows.Forms;
using DevExpress.XtraEditors;

namespace QLTB
{
    internal class MyBox
    {
        public static DialogResult ShowWarning(string message, string title)
        {
            return XtraMessageBox.Show(message, title, MessageBoxButtons.OK, MessageBoxIcon.Warning);
        }

        public static DialogResult ShowWarning(IWin32Window owner, string message, string title)
        {
            return XtraMessageBox.Show(owner, message, title, MessageBoxButtons.OK, MessageBoxIcon.Warning);
        }

        public static DialogResult ShowInfo(string message, string title)
        {
            return XtraMessageBox.Show(message, title, MessageBoxButtons.OK, MessageBoxIcon.Information);
        }

        public static DialogResult ShowQuestion(string message, string title)
        {
            return XtraMessageBox.Show(message, title, MessageBoxButtons.YesNo, MessageBoxIcon.Question);
        }

        public static DialogResult ShowSave(IWin32Window owner, string message, string title)
        {
            return XtraMessageBox.Show(owner, message, title, MessageBoxButtons.YesNoCancel, MessageBoxIcon.Warning);
        }

        public static DialogResult ShowSave(string message, string title)
        {
            return XtraMessageBox.Show(message, title, MessageBoxButtons.YesNoCancel, MessageBoxIcon.Warning);
        }
    }
}